package cn.qiyu5522.tk_ems.entity.dto;

import cn.qiyu5522.tk_ems.entity.Role;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * @ProjectName: tk_ems
 * @Package: cn.qiyu5522.tk_ems.entity.dto
 * @ClassName: RoleDTO
 * @Author: [Toneky]
 * @Date: 2023/3/2 18:23
 * @Version: V1.0
 **/
@Data
@ApiModel("角色DTO")
public class RoleDTO {
    @NotNull(message = "角色编号不能为空",groups = {Role.Update.class})
    private Integer id;

    @ApiModelProperty(value = "角色名")
    @NotBlank(message = "角色名不能为空",groups = {Role.Insert.class,Role.Update.class})
    private String name;

    @ApiModelProperty(value = "角色描述")
    @NotBlank(message = "角色描述不能为空",groups = {Role.Insert.class,Role.Update.class})
    private String description;

}
